<!DOCTYPE html>
<html lang="en">

    <head>
        <meta charset="UTF-8">
        <meta http-equiv="X-UA-Compatible" content="IE=edge">
        <meta name="viewport" content="width=device-width, initial-scale=1.0">
        <title>Document</title>
        <style>
            html,
            body {
                padding: 0;
                margin: 0;
                width: 100%;
                height: 100%;
                background-color: #000;
                display: flex;
            }

            #canvas {
                border: 1px solid #fff;
                margin: auto;
            }
        </style>
    </head>

    <body>
        <canvas id="canvas" width="800" height="800"></canvas>
        <script>
            const canvas = document.getElementById('canvas')
            const ctx = canvas.getContext('2d')

            class ball {
                constructor(size, x, y, color) {
                    this.size = size
                    this.x = x
                    this.y = y
                    this.spx = 2
                    this.spy = 2
                    this.color = `#${(~~(Math.random() * 0xffffff)).toString(16)}`
                }

                update(){
                    
                }

            }

        </script>
    </body>

</html>